unit uTestLoadImpl;


interface

type

  ITest = interface
  ['{05EB3549-6D58-4C56-92BA-799724FCB349}']
    function GetName: WideString;
    procedure SetName(Value: WideString);
    function GetQuestionsCnt: integer;
    procedure SetQuestionsCnt(Value: integer);
    function GetMixQuestions: boolean;
    procedure SetMixQuestions(Value: boolean);
    function GetMixVariants: boolean;
    procedure SetMixVariants(Value: boolean);
    function GetTimeLimit: integer;
    procedure SetTimeLimit(Value: integer);
    function GetAccessibility: boolean;
    procedure SetAccessibility(Value: boolean);
    function GetCanClose: boolean;
    procedure SetCanClose(Value: boolean);
    function GetShowComment: boolean;
    procedure SetShowComment(Value: boolean);
    function GetMaxBreaks: integer;
    procedure SetMaxBreaks(Value: integer);
    function GetGreeting: WideString;
    procedure SetGreeting(Value: WideString);
    function GetMaxPassings: integer;
    procedure SetMaxPassings(Value: integer);
    function GetCongratulations: WideString;
    procedure SetCongratulations(Value: WideString);
    function GetGroups: WideString;
    procedure SetGroups(Value: WideString);

    property Name: WideString read GetName write SetName;
    property QuestionsCnt: integer read GetQuestionsCnt write SetQuestionsCnt;
    property MixQuestions: boolean read GetMixQuestions write SetMixQuestions;
    property MixVariants: boolean read GetMixVariants write SetMixVariants;
    property TimeLimit: integer read GetTimeLimit write SetTimeLimit;
    property Accessibility: boolean read GetAccessibility write SetAccessibility;
    property CanClose: boolean read GetCanClose write SetCanClose;
    property ShowComment: boolean read GetShowComment write SetShowComment;
    property MaxBreaks: integer read GetMaxBreaks write SetMaxBreaks;
    property Greeting: WideString read GetGreeting write SetGreeting;
    property MaxPassings: integer read GetMaxPassings write SetMaxPassings;
    property Congratulations: WideString read GetCongratulations write SetCongratulations;
    property Groups: WideString read GetGroups write SetGroups;
  end;

  TTest = class(TInterfacedObject, ITest)
  private
    fName: WideString;
    fQuestionsCnt: integer;
    fMixQuestions: boolean;
    fMixVariants: boolean;
    fTimeLimit: integer;
    fAccessibility: boolean;
    fCanClose: boolean;
    fShowComment: boolean;
    fMaxBreaks: integer;
    fGreeting: WideString;
    fMaxPassings: integer;
    fCongratulations: WideString;
    fGroups: WideString;
  protected
    function GetName: WideString;
    procedure SetName(Value: WideString);
    function GetQuestionsCnt: integer;
    procedure SetQuestionsCnt(Value: integer);
    function GetMixQuestions: boolean;
    procedure SetMixQuestions(Value: boolean);
    function GetMixVariants: boolean;
    procedure SetMixVariants(Value: boolean);
    function GetTimeLimit: integer;
    procedure SetTimeLimit(Value: integer);
    function GetAccessibility: boolean;
    procedure SetAccessibility(Value: boolean);
    function GetCanClose: boolean;
    procedure SetCanClose(Value: boolean);
    function GetShowComment: boolean;
    procedure SetShowComment(Value: boolean);
    function GetMaxBreaks: integer;
    procedure SetMaxBreaks(Value: integer);
    function GetGreeting: WideString;
    procedure SetGreeting(Value: WideString);
    function GetMaxPassings: integer;
    procedure SetMaxPassings(Value: integer);
    function GetCongratulations: WideString;
    procedure SetCongratulations(Value: WideString);
    function GetGroups: WideString;
    procedure SetGroups(Value: WideString);
  end;

  function NewTestLoad: ITest;

implementation

{ TTest }

function TTest.GetAccessibility: boolean;
begin
  Result := fAccessibility;
end;

function TTest.GetCanClose: boolean;
begin
  Result := fCanClose;
end;

function TTest.GetCongratulations: WideString;
begin
  Result := fCongratulations;
end;

function TTest.GetGreeting: WideString;
begin
  Result := fGreeting;
end;

function TTest.GetGroups: WideString;
begin
  Result := fGroups;
end;

function TTest.GetMaxBreaks: integer;
begin
  Result := fMaxBreaks;
end;

function TTest.GetMaxPassings: integer;
begin
  Result := fMaxPassings;
end;

function TTest.GetMixQuestions: boolean;
begin
  Result := fMixQuestions;
end;

function TTest.GetMixVariants: boolean;
begin
  Result := fMixVariants;
end;

function TTest.GetName: WideString;
begin
  Result := fName;
end;

function TTest.GetQuestionsCnt: integer;
begin
  Result := fQuestionsCnt;
end;

function TTest.GetShowComment: boolean;
begin
  Result := fShowComment;
end;

function TTest.GetTimeLimit: integer;
begin
  Result := fTimeLimit;
end;

procedure TTest.SetAccessibility(Value: boolean);
begin
  fAccessibility := Value;
end;

procedure TTest.SetCanClose(Value: boolean);
begin
  fCanClose := Value;
end;

procedure TTest.SetCongratulations(Value: WideString);
begin
  fCongratulations := Value;
end;

procedure TTest.SetGreeting(Value: WideString);
begin
  fGreeting := Value;
end;

procedure TTest.SetGroups(Value: WideString);
begin
  fGroups := Value;
end;

procedure TTest.SetMaxBreaks(Value: integer);
begin
  fMaxBreaks := Value;
end;

procedure TTest.SetMaxPassings(Value: integer);
begin
  fMaxPassings := Value;
end;

procedure TTest.SetMixQuestions(Value: boolean);
begin
  fMixQuestions := Value;
end;

procedure TTest.SetMixVariants(Value: boolean);
begin
  fMixVariants := Value;
end;

procedure TTest.SetName(Value: WideString);
begin
  fName := Value;
end;

procedure TTest.SetQuestionsCnt(Value: integer);
begin
  fQuestionsCnt := Value;
end;

procedure TTest.SetShowComment(Value: boolean);
begin
  fShowComment := Value;
end;

procedure TTest.SetTimeLimit(Value: integer);
begin
  fTimeLimit := Value;
end;

function NewTestLoad: ITest;
begin
  Result := TTest.Create;
end;

end.
